program testelliptic
    use constants
    use dispmodule
    implicit none
    integer, parameter      :: dp = 8
    real(dp),dimension(:,:),allocatable     :: stats
    real(dp)                                          :: delta
    integer                          :: N,i, 
    integer,parameter                     :: file_handle = 100
  
    open( unit = file_handle , file='coaxial.out' , action='write' )
    
    print *,'Give number of rows in table:'
    read *,N
  
    allocate( stats(N,2)   )
    delta = ONE/real(N-1,dp)
  
    stats = ZERO

    do i=1,N
        stats(i,1) = i*delta
        stats(i,2) = EllipticK( i*delta )
    enddo
  
    call disp( stats , unit=file_handle , fmt = 'f25.16' )
  
    close( file_handle )
    deallocate( stats )
end program coaxial